package org.ishequ.db;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

public class DBOpenHelper extends SQLiteOpenHelper {

	public DBOpenHelper(Context context) {
		super(context, "ishequ.db", null, 1);
	}

	@Override
	public void onCreate(SQLiteDatabase db) {
		db.execSQL("create table sms(id integer primary key autoincrement, " +
				"sender varchar(20), receiver VARCHAR(20) ,receiverTime varchar(20) ," +
				" content varchar(140))");
		db.execSQL("create table phone(id integer primary key autoincrement, " +
				"sender varchar(20), receiver VARCHAR(20) ,receiverTime varchar(20) ," +
				" duration int ,audioName varchar(50),length integer," +
				"uploadPos integer,uploadTag boolean)");
	}

	@Override
	public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
		
	}

}
